#pragma once

#include <QVector3D>

#include <libz800.h>

#include "ui_DlgCalibVec.h"

class DlgCalibVec : public QDialog
		  , protected Ui_DlgCalibVec
{
	Q_OBJECT

public:
	DlgCalibVec(QWidget *parent = NULL);

public slots:
	void setDevice(z800_device *dev);
	void setRawData(const QVector3D &gyr, const QVector3D &acc, const QVector3D &mag);

protected slots:
	void on_startPushButton_pressed();
	void on_takeMeasurementPushButton_pressed();
	void on_calculatePushButton_pressed();

protected:
	QList<QVector3D> _magMeasurement;
	QList<QVector3D> _accMeasurement;

	QVector3D _gyr;
	QVector3D _acc;
	QVector3D _mag;

	z800_device *_dev;
};
